
<div id="function">
  <table width="500" border="0">
    <tr>
      <td>&nbsp;</td>
      <td>&nbsp;</td>
      <td>&nbsp;</td>
      <td>&nbsp;</td>
      <td>&nbsp;</td>
    </tr>
  </table>
</div>

<div id="post">
<div id="right">
  <div id="options">
    <%= render :layout=>"/login/user_function"  %>
  </div>
</div>

  <div id='content' >

  <fieldset>
<%  user=User.find_by_id(session[:user_id]) %>
<% vlteer=Volunteer.find_by_account(user.account) %>
    <% if vlteer %>
          <% aadmit = vlteer.admit %>
       <%if aadmit %>
          <div align="center"><h2>您已经是志愿者</h2></div>
         <% end %>
            <%if aadmit==false%>
            <div align="center">
                <h2>您的申请正在审核中请耐心等待</h2>
                 <h2>我们将在24小时内审核</h2>
            </div>
            <% end %>
    <%else%>
    <div id="reg_box">
           <h2>欢迎申请志愿者</h2>
                    <% form_for @volunteer, :url=>{:action=>"create"}do |f| %>
                       <%= f.error_messages %>
                       <div id="box_t">
                       <p>真实姓名：&nbsp;&nbsp;&nbsp; &nbsp; </p><%= f.text_field :name %>
                       <p>身份证号码：&nbsp;  &nbsp; &nbsp;&nbsp; &nbsp; &nbsp</p><%= f.text_field :identification %>
                       <p>性别：&nbsp;</p> <%= f.text_field :gender %>
                       <p><%= f.submit '申请' %></p>
                        <% end %>
                       </div>
               </div>
    <%end%>

    
      



  </fieldset>
 </div>
</div>